<template>
    <main-page style="padding: 2px 2px 0 2px">
        <el-tabs class="log-tabs" v-model="active" :tab-position="'top'" type="card">
            <el-tab-pane label="操作日志" name="first" style="height: 100%">
                <view-log/>
            </el-tab-pane>
            <el-tab-pane label="运行日志" name="second" style="height: 100%">
                <run-log v-if="active === 'second'"/>
            </el-tab-pane>
        </el-tabs>
    </main-page>
</template>

<script>
import {defineComponent, ref} from "vue";
import ViewLog from './log-view.vue'
import RunLog from './log-run.vue'

export default defineComponent({
    components: {ViewLog, RunLog},
    setup() {
        const active = ref('first')
        return {
            active
        };
    }
});
</script>

<style lang="scss" scoped>
.log-tabs {
    height: 100%;

    :deep(.el-tabs__header){
        margin: 0;
    }

    :deep(.el-tabs__item) {
        border-bottom: unset;
    }
}
</style>
